<%@ page language="java" import="java.util.*" pageEncoding="UTF-8" contentType="text/html; charset=utf-8" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<html>
<jsp:include page="../head.jsp"></jsp:include>
<body>
<form id='fmTbContact'  action='TbContactServlet' method='post'>
 <input type="hidden" name="method" id="method" value="${sessionScope.tbContact==null?'add':'edit'}" />
<input type="hidden" name="parDepartId" id="parDepartId" value="${sessionScope.parDepartId }"/> 
<input type="hidden" name="contactId" id="contactId" value="${sessionScope.tbContact.contactId }"/> 
<table>
<tr><td colspan="2"></td></tr>
<tr>
    <td>联系人姓名</td>
    <td><input type='text' name='contactName' id='contactName' value='${sessionScope.tbContact.contactName }' /></td>
</tr>
<tr>
    <td>性别</td>
    <td><input type="radio" name="contactSex"  id="contactSex"  value="0" ${sessionScope.tbContact.contactSex=='0'?'checked':''  } checked="checked"/>男&nbsp;
    <input type="radio" name="contactSex" id="contactSex" value="1" ${sessionScope.tbContact.contactSex=='1'?'checked':''  }/>女
   
    </td>
</tr>
<tr>
    <td>电话</td>
    <td><input type='text' name='contactPhone' id='contactPhone' value='${sessionScope.tbContact.contactPhone }' /></td>
</tr>
<tr>
    <td>邮箱</td>
    <td><input type='text' name='contactEmail' id='contactEmail' value='${sessionScope.tbContact.contactEmail }' /></td>
</tr>
<tr>
    <td>出生日期</td>
    <td>
    <input type='text' name='contactBirthday' id='contactBirthday' class="Wdate" size="20" readonly onclick="WdatePicker({el:this,dateFmt:'yyyy-MM-dd'})" value='${sessionScope.tbContact.contactBirthday}' />
    </td>
</tr>
<tr>
    <td>住址</td>
    <td><input type='text' name='contactAddress' id='contactAddress' value='${sessionScope.tbContact.contactAddress }' /></td>
</tr>
<tr>
    <td>类型</td>
    <td><input type="radio" name="contactState" id="contactState" value="0"  ${sessionScope.tbContact.contactState=='0'?'checked':''  }/>外部
    <input type="radio" name="contactState" id="contactState" value="1" ${sessionScope.tbContact.contactState==1?'checked':'' } checked="checked"/>内部
    <input type="radio" name="contactState" id="contactState" value="2" ${sessionScope.tbContact.contactState==2?'checked':'' }/>本人</td>
</tr>
<tr>
    <td colspan='2' align="center"><input type="submit" name="btsubmit" id="btsubmit" value="${sessionScope.tbContact==null?'添加':'修改'}" /><input type='reset' value='重置' /><input type='button' value='返回' onclick='history.go(-1);' /></td>
</tr></table>
</form><jsp:include page="../foot.jsp"></jsp:include>
</body></html>